﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:s="clr-namespace:MockupDesigner.AppItems"
                    xmlns:c="clr-namespace:MockupDesigner.Items"
                    xmlns:SketchControls="clr-namespace:Microsoft.Expression.Prototyping.SketchControls;assembly=Microsoft.Expression.Prototyping.SketchControls"
                    xmlns:ps="clr-namespace:Microsoft.Expression.Prototyping.SketchControls;assembly=Microsoft.Expression.Prototyping.SketchControls" 
                    xmlns:wpfToolkit="http://schemas.microsoft.com/wpf/2008/toolkit"
                    xmlns:ac="clr-namespace:MockupDesigner.AdditionalControls">

    <!-- Control Templates For Items-->
    <ControlTemplate x:Key="DataGridItemTemplate" TargetType="{x:Type c:DataGridItem}">
        <c:DataGridControl AutoGenerateColumns="True" CanUserAddRows="false" CanUserSortColumns="False" 
            HeadersVisibility="{Binding Path=HeadersVisibility, RelativeSource={RelativeSource AncestorType={x:Type c:DataGridItem}}}"
            ItemsSource="{Binding Path=ItemsSource, RelativeSource={RelativeSource AncestorType={x:Type c:DataGridItem}}}"
            Style="{DynamicResource DataGridStyle}"
            ColumnHeaderStyle="{DynamicResource ColumnHeaderStyle}" 
            CellStyle="{DynamicResource CellStyle}"/>
    </ControlTemplate>

    <!-- ToolBox -->
    <s:Toolbox x:Key="DataToolbox">
        <c:DataGridItem ToolTip="DataGrid" IsHitTestVisible="False" 
            Height="50" Width="100"
            HeadersVisibility="Column"
            Template="{DynamicResource DataGridItemTemplate}"/>
    </s:Toolbox>
</ResourceDictionary>